import request from '@/utils/request'

const dict = {
  listPost(query) {
    return request({
      url: 'admin/sys-post/page/'+query.pageNum+'/'+query.pageSize,
      method: 'get',
      params: query

    })
  },
  getPost(id) {
    return request({
      url: 'admin/sys-post/get/'+id,
      method: 'get'

    })
  },
  delPost(ids) {
    return request({
      url: 'admin/sys-post/remove/'+ids,
      method: 'delete'

    })
  },
  addPost(data) {
    return request({
      url: 'admin/sys-post/create',
      method: 'post',
      data: data

    })
  },
  updatePost(data) {
    return request({
      url: 'admin/sys-post/update',
      method: 'put',
      data: data

    })
  },
  exportPost(query) {
    return request({
      url: 'admin/sys-post/export',
      method: 'get',
      params: query

    })
  },
}

export default dict
